#include <iostream>

using namespace std;

int main()
{
    int v[100],n,i,p=1,s=0,e;
    std::cout<<"n=";std::cin>>n;
    for(i=0;i<n;i++)
    {
        std::cout<<"v["<<i<<"]=";
        std::cin>>v[i];
    }
    for(i=0;i<n;i++)
    {
    p=p*v[i];
    s=s+v[i];}
    e=s+p;
    std::cout<<"p="<<p<<endl;
    std::cout<<"s="<<s<<endl;
    std::cout<<"e="<<e<<endl;
    return 0;
}

